package com.ruoyi.common.utils;

import cn.hutool.core.lang.id.NanoId;

/**
 * ShortUrlUtils
 *
 * @author liliangyu
 */
public class ShortUrlUtils {

    private static final String ALPHABET = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ";


    /**
     * 生成key
     *
     * @return
     */
    public static String generateKey() {
        return NanoId.randomNanoId(null, ALPHABET.toCharArray(), 10);
    }
}
